using System;

namespace Common.Unity.Extensions.PropertyMapper
{
	[AttributeUsage( AttributeTargets.Property,	AllowMultiple = true )]
	public class PropertyMappingAttribute : Attribute
	{
		readonly Type targetType;
		readonly string expression;

		public PropertyMappingAttribute( Type targetType )
		{
			this.targetType = targetType;
		}

		public PropertyMappingAttribute( Type targetType, string expression )
		{
			this.targetType = targetType;
			this.expression = expression;
		}

		public Type TargetType
		{
			get { return targetType; }
		}

		public string Expression
		{
			get { return expression; }
		}

		public Type TypeConverterType { get; set; }
	}
}